package com.aura.blog.dto.request;

import io.swagger.v3.oas.annotations.media.Schema;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.NotNull;
import lombok.Data;
import org.hibernate.validator.constraints.Length;

@Data
@Schema(description = "添加博客请求对象")
public class AddBlogRequest {
    
    @NotNull(message = "作者不能为空")
    @Schema(description = "作者ID")
    private Integer userId;

    @NotBlank(message = "标题不能为空")
    @Length(max = 20, message = "标题不能超过20")
    @Schema(description = "博客标题", example = "我的第一篇博客")
    private String title;

    @NotBlank(message = "内容不能为空")
    @Schema(description = "博客内容", example = "这是博客的详细内容...")
    private String content;
}